package com.test.common;

import java.util.concurrent.CountDownLatch;

import javax.servlet.annotation.WebListener;
import javax.servlet.http.HttpSessionEvent;
import javax.servlet.http.HttpSessionListener;

import org.apache.catalina.SessionEvent;
import org.apache.catalina.SessionListener;
@WebListener
public class PersonAccountListener implements HttpSessionListener {
	public int count= 0;
	@Override
	public void sessionCreated(HttpSessionEvent se) {
		count++;
		se.getSession().setAttribute("count", count);
	}

	@Override
	public void sessionDestroyed(HttpSessionEvent se) {
		count--;
		se.getSession().setAttribute("count", count);
	}

	
	

}
